3.384 \(\int \sec ^2(c+d x) (a+b \sin (c+d x)) \, dx\)

Optimal. Leaf size=23 \[ \frac{a \tan (c+d x)}{d}+\frac{b \sec (c+d x)}{d} \]

[Out]

(b*Sec[c + d*x])/d + (a*Tan[c + d*x])/d

________________________________________________________________________________________

Rubi [A]  time = 0.0311392, antiderivative size = 23, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 3, integrand size = 19, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.158, Rules used = {2669, 3767, 8} \[ \frac{a \tan (c+d x)}{d}+\frac{b \sec (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Int[Sec[c + d*x]^2*(a + b*Sin[c + d*x]),x]

[Out]

(b*Sec[c + d*x])/d + (a*Tan[c + d*x])/d

Rule 2669

Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> -Simp[(b*(g*Cos[
e + f*x])^(p + 1))/(f*g*(p + 1)), x] + Dist[a, Int[(g*Cos[e + f*x])^p, x], x] /; FreeQ[{a, b, e, f, g, p}, x]
&& (IntegerQ[2*p] || NeQ[a^2 - b^2, 0])

Rule 3767

Int[csc[(c_.) + (d_.)*(x_)]^(n_), x_Symbol] :> -Dist[d^(-1), Subst[Int[ExpandIntegrand[(1 + x^2)^(n/2 - 1), x]
, x], x, Cot[c + d*x]], x] /; FreeQ[{c, d}, x] && IGtQ[n/2, 0]

Rule 8

Int[a_, x_Symbol] :> Simp[a*x, x] /; FreeQ[a, x]

Rubi steps

\begin{align*} \int \sec ^2(c+d x) (a+b \sin (c+d x)) \, dx &=\frac{b \sec (c+d x)}{d}+a \int \sec ^2(c+d x) \, dx\\ &=\frac{b \sec (c+d x)}{d}-\frac{a \operatorname{Subst}(\int 1 \, dx,x,-\tan (c+d x))}{d}\\ &=\frac{b \sec (c+d x)}{d}+\frac{a \tan (c+d x)}{d}\\ \end{align*}

Mathematica [A]  time = 0.0110951, size = 23, normalized size = 1. \[ \frac{a \tan (c+d x)}{d}+\frac{b \sec (c+d x)}{d} \]

Antiderivative was successfully verified.

[In]

Integrate[Sec[c + d*x]^2*(a + b*Sin[c + d*x]),x]

[Out]

(b*Sec[c + d*x])/d + (a*Tan[c + d*x])/d

________________________________________________________________________________________

Maple [A]  time = 0.028, size = 24, normalized size = 1. \begin{align*}{\frac{1}{d} \left ( a\tan \left ( dx+c \right ) +{\frac{b}{\cos \left ( dx+c \right ) }} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sec(d*x+c)^2*(a+b*sin(d*x+c)),x)

[Out]

1/d*(a*tan(d*x+c)+b/cos(d*x+c))

________________________________________________________________________________________

Maxima [A]  time = 0.955777, size = 31, normalized size = 1.35 \begin{align*} \frac{a \tan \left (d x + c\right ) + \frac{b}{\cos \left (d x + c\right )}}{d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^2*(a+b*sin(d*x+c)),x, algorithm="maxima")

[Out]

(a*tan(d*x + c) + b/cos(d*x + c))/d

________________________________________________________________________________________

Fricas [A]  time = 2.05694, size = 53, normalized size = 2.3 \begin{align*} \frac{a \sin \left (d x + c\right ) + b}{d \cos \left (d x + c\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^2*(a+b*sin(d*x+c)),x, algorithm="fricas")

[Out]

(a*sin(d*x + c) + b)/(d*cos(d*x + c))

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \left (a + b \sin{\left (c + d x \right )}\right ) \sec ^{2}{\left (c + d x \right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)**2*(a+b*sin(d*x+c)),x)

[Out]

Integral((a + b*sin(c + d*x))*sec(c + d*x)**2, x)

________________________________________________________________________________________

Giac [A]  time = 1.09731, size = 45, normalized size = 1.96 \begin{align*} -\frac{2 \,{\left (a \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + b\right )}}{{\left (\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} - 1\right )} d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sec(d*x+c)^2*(a+b*sin(d*x+c)),x, algorithm="giac")

[Out]

-2*(a*tan(1/2*d*x + 1/2*c) + b)/((tan(1/2*d*x + 1/2*c)^2 - 1)*d)